#include "TransformationSection.h"


TransformationSection::TransformationSection(void)
{
}


TransformationSection::~TransformationSection(void)
{
}

void TransformationSection::Init(Program * program)
{
	worldMatrixLocation = program->GetUniformLocation("worldMatrix");
	viewMatrixLocation = program->GetUniformLocation("viewMatrix");
	projectionMatrixLocation = program->GetUniformLocation("projectionMatrix");
}

void TransformationSection::SetWorldMatrix(glm::mat4 * matrix)
{
	glUniformMatrix4fv(worldMatrixLocation, 1, GL_FALSE, (float*)&matrix[0][0]);
}

void TransformationSection::SetViewMatrix(glm::mat4 * matrix)
{
	glUniformMatrix4fv(viewMatrixLocation, 1, GL_FALSE, (float*)&matrix[0][0]);
}

void TransformationSection::SetProjectionMatrix(glm::mat4 * matrix)
{
	glUniformMatrix4fv(projectionMatrixLocation, 1, GL_FALSE, (float*)&matrix[0][0]);
}